//------------------------------------------------------------------------------
// Copyright (c) 2012 by Silicon Laboratories. 
// All rights reserved. This program and the accompanying materials
// are made available under the terms of the Silicon Laboratories End User 
// License Agreement which accompanies this distribution, and is available at
// http://developer.silabs.com/legal/version/v10/License_Agreement_v10.htm
// Original content and implementation provided by Silicon Laboratories.
//------------------------------------------------------------------------------

#include <stdio.h>

#include <si32_device.h>

#include "myUART0.h"

//------------------------------------------------------------------------------
// Precision32 Support Functions

int __sys_write(int iFileHandle, char *pcBuffer, int iLength)
{
  int i;
  for (i = 0; i<iLength; i++)
  {
    myUART0_send_char(pcBuffer[i]); // print each character
  }
  return iLength;
}

int __sys_readc(void)
{
  int c;
  c = myUART0_get_char();
  return c;
}

//-eof--------------------------------------------------------------------------
